package com.ruoyi.schedule.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.schedule.mapper.StudentCourseScheduleMapper;
import com.ruoyi.schedule.domain.StudentCourseSchedule;
import com.ruoyi.schedule.service.IStudentCourseScheduleService;

/**
 * 学生课程计划Service业务层处理
 *
 * @author dongyv
 * @date 2025-05-15
 */
@Service
public class StudentCourseScheduleServiceImpl implements IStudentCourseScheduleService
{
    @Autowired
    private StudentCourseScheduleMapper studentCourseScheduleMapper;

    /**
     * 查询学生课程计划
     *
     * @param id 学生课程计划主键
     * @return 学生课程计划
     */
    @Override
    public StudentCourseSchedule selectStudentCourseScheduleById(Long id)
    {
        return studentCourseScheduleMapper.selectStudentCourseScheduleById(id);
    }

    /**
     * 查询学生课程计划列表
     *
     * @param studentCourseSchedule 学生课程计划
     * @return 学生课程计划
     */
    @Override
    public List<StudentCourseSchedule> selectStudentCourseScheduleList(StudentCourseSchedule studentCourseSchedule)
    {
        return studentCourseScheduleMapper.selectStudentCourseScheduleList(studentCourseSchedule);
    }

    /**
     * 新增学生课程计划
     *
     * @param studentCourseSchedule 学生课程计划
     * @return 结果
     */
    @Override
    public int insertStudentCourseSchedule(StudentCourseSchedule studentCourseSchedule)
    {
        return studentCourseScheduleMapper.insertStudentCourseSchedule(studentCourseSchedule);
    }

    /**
     * 修改学生课程计划
     *
     * @param studentCourseSchedule 学生课程计划
     * @return 结果
     */
    @Override
    public int updateStudentCourseSchedule(StudentCourseSchedule studentCourseSchedule)
    {
        return studentCourseScheduleMapper.updateStudentCourseSchedule(studentCourseSchedule);
    }

    /**
     * 批量删除学生课程计划
     *
     * @param ids 需要删除的学生课程计划主键
     * @return 结果
     */
    @Override
    public int deleteStudentCourseScheduleByIds(Long[] ids)
    {
        return studentCourseScheduleMapper.deleteStudentCourseScheduleByIds(ids);
    }

    /**
     * 删除学生课程计划信息
     *
     * @param id 学生课程计划主键
     * @return 结果
     */
    @Override
    public int deleteStudentCourseScheduleById(Long id)
    {
        return studentCourseScheduleMapper.deleteStudentCourseScheduleById(id);
    }

    @Override
    public List<StudentCourseSchedule> selectStudentCourseScheduleList_handteacher(String teacherId) {
        return studentCourseScheduleMapper.selectStudentCourseScheduleList_handteacher(teacherId);
    }

}
